import request from '@/utils/request'

// 查询论坛用户列表
export function listBbs_user1(query) {
	return request({
		url: '/bbs_user/bbs_user/list',
		method: 'get',
		params: query
	})
}

export function listBbs_user(query) {
	return request({
		url: '/bbs_user/bbs_user/list',
		method: 'post',
		params: query
	})
}

export function getAllSchools(query) {
	return request({
		url: '/bbs_user/bbs_user/schoolList',
		method: 'get',
		params: query
	})
}

// 查询论坛用户详细
export function getBbs_user(userid) {
	return request({
		url: '/bbs_user/bbs_user/' + userid,
		method: 'get'
	})
}

// 新增论坛用户
export function addBbs_user(data) {
	return request({
		url: '/bbs_user/bbs_user',
		method: 'post',
		data: data
	})
}

// 修改论坛用户
export function updateBbs_user(data) {
	return request({
		url: '/bbs_user/bbs_user',
		method: 'put',
		data: data
	})
}

// 删除论坛用户
export function delBbs_user(userid) {
	return request({
		url: '/bbs_user/bbs_user/' + userid,
		method: 'delete'
	})
}
//认证用户
export function judgeBbs_user(query) {
	return request({
		url: '/bbs_user/bbs_user/judge',
		method: 'post',
		params: query
	})
}

//发送小程序模板通知
export function sendSubscribeMessage(query) {
	return request({
		//南师
		// baseURL: '/remoteApi',
		//南财
		// baseURL: '/remoteApi-nufe',
		//逛逛
		// baseURL: '/remoteApi-guangguang',
		//测试
		// baseURL: '/remoteApi-test',
		//学喵
		baseURL: '/remoteApi-xuemiao',
		url: '/commonAPIs/sendSubscribeMessage',
		method: 'post',
		params: query
	})
}

//认证后修改用户积分
export function addRewardScore(query) {
	return request({
		//南师
		// baseURL: '/remoteApi',
		//南财
		// baseURL: '/remoteApi-nufe',
		//逛逛
		// baseURL: '/remoteApi-guangguang',
		//测试
		// baseURL: '/remoteApi-test',
		//学喵
		baseURL: '/remoteApi-xuemiao',
		url: '/score/changeUserScore',
		method: 'post',
		params: query
	})
}

// 查询论坛机器人列表
export function listBbs_robot(query) {
	return request({
		url: '/bbs_user/bbs_user/robotList',
		method: 'get',
		params: query
	})
}

//更新咨询群成员
export function updateGroupMember(query) {
	return request({
		url: '/bbs_user/bbs_user/updateGroupMember',
		method: 'get',
		params: query,
	})
}

export function getUserSchool(query) {
	return request({
		url: '/bbs_user/bbs_user/getUserSchool',
		method: 'get',
		params: query,
	})
}

// 修改论坛用户官方认证状态
export function changeUserState(data) {
	return request({
		url: '/bbs_user/bbs_user/changeUserState',
		method: 'put',
		data: data
	})
}

export function allSchoolUserList(query) {
	return request({
		url: '/bbs_user/bbs_user/allSchoolUserList',
		method: 'get',
		params: query
	})
}


